<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0"
	xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
	<xsl:template match="/">
		<table width="100%">
			<tr>
				<th>Remove</th>
				<th>User</th>
				<th>Instrument</th>
				<th>Start Time</th>
				<th>End Time</th>
			</tr>
			<xsl:apply-templates select="//reservation" />
		</table>
	</xsl:template>
	<xsl:template match="reservation">


		<tr>
			<td>
				<xsl:if test="can_cancel&gt;0">
					<form method="post" action="">
						<div>
							<input type="submit" name="CancelReservetion" value="Cancel" />
							<input type="hidden" name="userLogin" value="{./userLogin}" />
							<input type="hidden" name="instrumentID" value="{./instrument/@id}" />
							<input type="hidden" name="startTimestamp" value="{./startTimestamp}" />
						</div>
					</form>
				</xsl:if>
			</td>
			<td>
				<xsl:value-of select="userName" />
				(
				<xsl:value-of select="userLogin" />
				)
			</td>
			<td>
				<xsl:value-of select="instrument/type" />
				(
				<xsl:value-of select="instrument/@id" />
				)
			</td>
			<td>
				<xsl:value-of select="startTime" />
			</td>
			<td>
				<xsl:value-of select="endTime" />
			</td>
		</tr>
	</xsl:template>
</xsl:stylesheet>